const fs = require('fs');

fs.writeFile('./temp.txt', '123456asga', err => {
    if (err) {
        console.log('fail')
    }
    console.log('写入成功')
})